package com.liner.string;

/**
 *  将其它数据类型转换为String
 */
public class ValueOfDemo {
    public static void main(String[] args) {
        int value = 12;
        double value2 = 12.12;
        String s1 = String.valueOf(value);
        String s2 = String.valueOf(value2);
        String s3 = value + " "; //效率低
        System.out.println(s1 + " , " + s2 + " , " + s3);
    }

}
